<template>
    <MainDetails />
    <BgLine/>
    <div class="main_img"></div>
    <FooterMenu />
</template>

<script setup>
import MainDetails from "@components/MainDetails/index.vue";
import FooterMenu from "@components/Footer/index.vue";
import BgLine from '@components/BgLine/index.vue'
import {useRoute} from 'vue-router';
import {useStore } from 'vuex';
import http from "../../http";
let router = useRoute();
let inviter = router.query.inviter;
const _useStore = useStore();
const commit = _useStore.commit;
const active = async function(){
    let res = await http.get(`/api/user/isActive`);
    if(res.code === 200){
        if(!res.data){
            commit('changeOverlayName',{name: 'ActivationAddress', params: {address: inviter}});
        }
    }
};
if(inviter){
    active();
}
</script>

<style scoped lang="scss">
.index {
  font-size: 20px;
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.main_img {
  background: url("@/assets/index/WechatIMG2.png") no-repeat center;
  background-size: cover;
  flex: 1;
}
</style>
